package com.qqt.csr.archive.enums;

import java.util.Arrays;

/**
 * @Author: yang hao
 * @Date: 2024/11/19 9:45
 * @Description: 账户类型
 **/
public enum AccountType {

    SYSTEM,

    ROBOT,

    CUSTOMER_SERVICE,

    VISITOR,

    ;

    /**
     * 匹配账户类型
     * @param name {@link String} 账户类型名称
     * @return {@link AccountType} 账户类型
     */
    public static AccountType matchIgnoreCase(String name) {
        return Arrays.stream(values())
                .filter(e -> e.name().equalsIgnoreCase(name))
                .findFirst()
                .orElse(null);
    }

}
